package com.swit.mobile.log;

import	com.swit.mobile.servlet.*;

import	javax.servlet.http.*;

public class CommandInsert implements Command{
	private String _next;
	private String class_nm ;

	public CommandInsert(String next){
		_next  = next;
		class_nm = getClass().toString();
	}

	public String execute(HttpServletRequest req) throws CommandException{
		try{
			BaseBean bean = Repository.getInstance().insert(req);			
			
			req.setAttribute("bean",bean);
			
		}catch(Exception e){
			throw new CommandException(class_nm+".execute() : " + e.getMessage());
		}
		return _next;
	}
}